module.exports = app =>{
        const {router, controller} = app;
        var adminauthor = app.middleware.adminauthor()
        router.post('/admin/checklogin',controller.admin.main.checklogin);
        router.post('/admin/addArticle',adminauthor,controller.admin.main.addArticle)      
        router.post('/admin/updateArticle',adminauthor,controller.admin.main.updateArticle)
        router.post('/admin/saveArticle',adminauthor,controller.admin.main.saveArticle)
        router.post('/admin/updateSaveArticle',adminauthor,controller.admin.main.updateSaveArticle)
        router.get('/admin/getArticleList',adminauthor,controller.admin.main.getArticleList)
        router.get('/admin/getSaveArticle',adminauthor,controller.admin.main.getSaveArticle) 
        router.get('/admin/deleteArticle/:id',adminauthor,controller.admin.main.deleteArticle)
        router.get('/admin/editArtcile/:id',adminauthor,controller.admin.main.editArtcile)
        router.get('/admin/deleteDrafts/:id',adminauthor,controller.admin.main.deleteDrafts)
        router.get('/admin/editDrafts/:id',adminauthor,controller.admin.main.editDrafts)
}